class Person:
    def __init__(self,name,weight):
        self.name = name
        self.weight = weight
    def __str__(self):
        return f'{self.name}目前的体重为{self.weight}'

    def run(self):
        self.weight -= 0.5
        print(f'{self.weight}跑步了,体重减了0.5公斤')

    def eat(self):
        self.weight += 1
        print(f'{self.name}大吃了一顿,体重增加了1公斤')




person = Person('李四',70)
print(person)
person.run()
print(person)
person.eat()
print(person)



